package com.android.broad;

public interface Constants {
  String LOG_TAG = MainBroadCast.class.getSimpleName();

  long THREAD_POSTER_SLEEP_DURATION = 3000;

  // String REST_APP_URL = "http://webapp.tetedebois.org/det/";
  // String REST_APP_URL = "http://192.168.1.1:8080/det/events";
  // String REST_APP_URL = "http://localhost/events";
  String REST_APP_URL = "http://webapp.tetedebois.org/det-rest/events";
  int REST_IMPL_DEFAULT = 1;
  int REST_IMPL_SYMFONY = 2;
  int REST_IMPL_RAILS = 3;
  int REST_IMPL = REST_IMPL_DEFAULT;

  String REST_PARAM_NAME_DEVICE_ID = "deviceId";
  String REST_PARAM_NAME_TYPE = "type";
  String REST_PARAM_NAME_TIMESTAMP = "timestamp";
  String REST_PARAM_NAME_PARAMS = "params";

  String SQLITE_DB_NAME = MainBroadCast.class.getSimpleName() + ".db";
  String SQLITE_EVENT_TABLE_NAME = "event";
  String SQLITE_EVENT_ID_COLUMN_NAME = "event_id";
  String SQLITE_DEVICE_ID_COLUMN_NAME = "device_id";
  String SQLITE_EVENT_TYPE_COLUMN_NAME = "event_type";
  String SQLITE_EVENT_TIMESTAMP_COLUMN_NAME = "event_timestamp";
  String SQLITE_EVENT_PARAMS_COLUMN_NAME = "event_params";

  String SQLITE_CREATE_EVENT_TABLE_SQL_REQUEST = "CREATE TABLE "
      + SQLITE_EVENT_TABLE_NAME + " (" + SQLITE_EVENT_ID_COLUMN_NAME
      + " INTEGER PRIMARY KEY AUTOINCREMENT, " + SQLITE_DEVICE_ID_COLUMN_NAME
      + " VARCHAR(250) NOT NULL, " + SQLITE_EVENT_TYPE_COLUMN_NAME
      + " VARCHAR(250) NOT NULL, " + SQLITE_EVENT_TIMESTAMP_COLUMN_NAME
      + " INTEGER NOT NULL, " + SQLITE_EVENT_PARAMS_COLUMN_NAME
      + " VARCHAR(250)" + ")";
  int SQLITE_DB_VERSION = 1;

  String ACTION_SMS_RECEIVED = "android.provider.Telephony.SMS_RECEIVED";

  String EVENT_TYPE_BROADCAST = "broadcast";
  String EVENT_TYPE_PHONE_STATE_CHANGED = "phone state changed";
  String EVENT_TYPE_OUTGOING_PHONE_CALL = "outgoing phone call";
  String EVENT_TYPE_SMS_RECEIVED = "sms received";

  String EVENT_TYPE_LOCATION = "location";
  String EVENT_TYPE_LOCATION_STATUS = "location status";
  String EVENT_TYPE_LOCATION_PROVIDER_DISABLED = "location provider disabled";
  String EVENT_TYPE_LOCATION_PROVIDER_ENABLED = "provider enabled";
  String EVENT_TYPE_CONNECTIVITY_CHANGED = "connectivity changed";

  // long LOCATION_MIN_UPDATE_TIME = 1000l * 60 * 5;
  // float LOCATION_MIN_UPDATE_DISTANCE = 500f;


  boolean DEBUG_ONLY_LOG_EVENT = true;
}
